﻿<!DOCTYPE HTML>
<html xmlns="http://www.w3.org/1999/xhtml"
	  xmlns:th="http://www.thymeleaf.org" lang="zh">
<head th:replace="common/header::header">
</head>
<body>
<nav class="breadcrumb">
	<i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> 日志管理 <span class="c-gray en">&gt;</span> 日志信息 <a id="btn-refresh" class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" onclick="refresh()" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
<div class="page-container" id="form_data">
	<section class="text-c" id="search"> 日期范围：
		<input type="text" onfocus="WdatePicker({ maxDate:'#F{$dp.$D(\'datemax\')||\'%y-%M-%d\'}' })" id="datemin" class="input-text Wdate" style="width:120px;"/>
		-
		<input type="text" onfocus="WdatePicker({ minDate:'#F{$dp.$D(\'datemin\')}',maxDate:'%y-%M-%d' })" id="datemax" class="input-text Wdate" style="width:120px;"/>
		&emsp;&emsp;日志类型：
		<span class="select-box inline">
			<select id="logTypeId" name="logTypeId" class="select" style="width: 170px">
				<option value="">全部分类</option>
				<option th:each="logType:${logTypes}" th:value="${logType.logTypeId}" th:text="${logType.typeName}"></option>
			</select>
		</span>
		<button type="submit" class="btn btn-success" id="query" name=""><i class="Hui-iconfont">&#xe665;</i> 搜日志</button>
	</section>
	<div id="retrieve_data">
		<div class="cl pd-5 bg-1 bk-gray mt-20">
			<span class="l">
				<a href="javascript:;" onclick="datadel()" class="btn btn-danger radius"><i class="Hui-iconfont">&#xe6e2;</i> 批量删除</a>
				<a href="javascript:;" onclick="download_excel()" class="btn btn-secondary radius"><i class="Hui-iconfont">&#xe640;</i> 导出EXCEL</a>
			</span>
		<span class="r">共有数据：<strong th:text="${lists.total}">54</strong> 条</span>
		</div>
		<div class="mt-20" id="page_data">
			<table class="table table-border table-bordered table-bg table-hover table-sort">
				<thead>
				<tr class="text-c">
					<th width="25"><input type="checkbox" name="subCheck" id="subCheck"/></th>
					<th width="40">序号</th>
					<th width="">日志类型</th>
					<th width="">操作用户</th>
					<th width="">操作时间</th>
					<th width="">请求路径</th>
					<th width="">响应状态</th>
					<th width="">是否有效</th>
					<th width="">备注</th>
					<th width="">操作</th>
				</tr>
				</thead>
				<tbody>
				<tr class="text-c" th:each="item:${lists}">
					<td><input type="checkbox" th:attr="value=${item.logId}" name="subCheck" /></td>
					<td th:text="${itemStat.count}"></td>
					<td th:text="${item.typeName}"></td>
					<td th:text="${item.userName}"></td>
					<td th:text="${#dates.format(item.operateTime,'yyyy-MM-dd HH:mm:ss')}"></td>
					<td th:text="${item.requestUrl}"></td>
					<td th:text="${item.responseCode}==0?'成功':'失败'"></td>
					<td th:text="${item.status}==1?'有效':'无效'"></td>
					<td th:text="${item.remark}"></td>
					<td class="td-manage">
						<a title="详情" href="javascript:;" th:onclick="'javascript:log_show(\''+${item.logId}+'\')'" class="ml-5" style="text-decoration:none"><i class="Hui-iconfont">&#xe665;</i></a>
						<a title="删除" href="javascript:;" th:onclick="'javascript:log_del(\''+${item.logId}+'\')'" class="ml-5" style="text-decoration:none"><i class="Hui-iconfont">&#xe6e2;</i></a>

					</td>
				</tr>
				</tbody>
			</table>
			<script th:include="common/pages::pages" th:inline="javascript"></script>
		</div>
	</div>
</div>
<footer th:replace="common/footer::footer"></footer>
<script th:src="@{/js/log/logList.js}" th:inline="javascript"></script>
</body>
</html>